home *** CD-ROM | disk | FTP | other *** search
/ Aminet 2 / Aminet AMIGA CDROM (1994)(Walnut Creek)[Feb 1994][W.O. 44790-1].iso / Aminet / gfx / show / JPEGv42source.lha / GC / JPEG / mpic_defs.h < prev    next >
C/C++ Source or Header  |  1993-06-05  |  5KB  |  103 lines

  1.  
  2. #include <utility/tagitem.h>
  3.  
  4. /* ------------------------------------------------------------*/
  5. #define MULTIPIC_LIB_VERSION     0           /* the current version of multipic.library*/
  6. /* ------------------------------------------------------------*/
  7. /* values for _pi_FileType:*/
  8. #define PFT_UNKNOWN              0           /* UNKONWN image type, unable to load*/
  9. #define PFT_ILBM                 1           /* IFF ILBM*/
  10. #define PFT_DEEP                 2           /* IFF DEEP*/
  11. #define PFT_BMP                  3           /* BMP*/
  12. #define PFT_RGB8                 4           /* IFF RGB8*/
  13. #define PFT_RGBN                 5           /* IFF RGBN*/
  14. #define PFT_YUVN                 6           /* IFF YUVN*/
  15. #define PFT_VLAB                 7           /* IFF VLAB, private VLab format*/
  16. #define PFT_PGM                  8           /* PGM*/
  17. #define PFT_PPM                  9           /* PPM*/
  18. #define PFT_QRT                  10          /* QRT*/
  19. #define PFT_SUNRASTER            11          /* SUNRASTER*/
  20. #define PFT_XIPAINT              12          /* XIPAINT, private VDPaint format*/
  21.  
  22. /*values for _pi_Flags:*/
  23. #define PIF_IFF (1 << 0)                /* image is stored in an IFF file format*/
  24. #define PIF_ORIGIN_BOTTOM (1 << 1)      /* image is stored upside down*/
  25.  
  26. struct PicInfo {
  27.  long           pi_Flags;               /* see definitions above*/
  28.  char *         pi_FileName;            /* name of the file (provided to Open() )*/
  29.  char *         pi_TypeName;            /* file type, ascii identifier*/
  30.  short          pi_Type;                /* see PFT_xxx above*/
  31.  
  32.  short          pi_Width;               /* The width of the image.*/
  33.  short          pi_Height;              /* The height of the image.*/
  34.  short          pi_PageWidth;           /* The page width of the image.*/
  35.  short          pi_PageHeight;          /* The page height of the image.*/
  36.  
  37.  BYTE           i_AspectX;             /* The X aspect of the image    ny*/
  38.  BYTE           i_AspectY;             /* The Y aspect of the image    ny*/
  39.  
  40.  unsigned short          pi_CMapEntries;         /* 2..256 with 8 bit images*/
  41.                                         /* 0 or 256 with 24 bit true color images*/
  42.  unsigned short          pi_CMapSize_RGB;
  43.  unsigned short          pi_CMapSize_RRGGBB;
  44.  unsigned short          pi_CMapSize_RGB4;
  45.  unsigned short          pi_CMapSize_RGB32;
  46.  unsigned short          pi_CMapSize_Res1;       /* currently always 0*/
  47.  unsigned short          pi_CMapSize_Res2;       /* currently always 0*/
  48.  
  49.  unsigned char           pi_Depth;               /* 1..8,12,24,32*/
  50.  unsigned char           pi_BytesPerPixel;       /* 1, 3, 4*/
  51.  
  52.  unsigned char          pi_RedBits;             /* 1..8  \                     //not yet*/
  53.  unsigned char          pi_GreenBits;           /* 1..8   \ for                //not yet*/
  54.  unsigned char          pi_BlueBits;            /* 1..8   / TRUE-COLOR         //not yet*/
  55.  unsigned char          pi_AlphaBits;           /* 1..8  /                     //not yet*/
  56.  unsigned char          pi_Reserved1Bits;       /* currently always 0*/
  57.  unsigned char          pi_Reserved2Bits;       /* currently always 0*/
  58. };
  59.  
  60. /* ------------------------------------------------------------*/
  61. /* Flags for BAT_Flags:*/
  62. #define BAF_MERGEPALETTE (1 << 0)        /*recalculate 24 bit true color data if a palette is present*/
  63.  
  64. /* Tags for MP_SetBufferAttrs*/
  65.  
  66. #define MP_TagBase                           TAG_USER+0x800       /* Begin counting tags*/
  67. #define BAT_Inc                              MP_TagBase+1        /**/
  68. #define BAT_RedInc                           MP_TagBase+2        /**/
  69. #define BAT_GreenInc                         MP_TagBase+3        /**/
  70. #define BAT_BlueInc                          MP_TagBase+4        /**/
  71. #define BAT_AlphaInc                         MP_TagBase+5        /*not yet*/
  72. #define BAT_DefaultAlphaValue                MP_TagBase+6        /*not yet*/
  73. #define BAT_Flags                            MP_TagBase+7        /*not yet*/
  74. #define BAT_LeftEdge                         MP_TagBase+8        /**/
  75. #define BAT_TopEdge                          MP_TagBase+9        /**/
  76. #define BAT_Width                            MP_TagBase+10       /**/
  77.  
  78. #define BAT_Mod                              MP_TagBase+11       /*not yet*/
  79. #define BAT_RedMod                           MP_TagBase+12       /*not yet*/
  80. #define BAT_GreenMod                         MP_TagBase+13       /*not yet*/
  81. #define BAT_BlueMod                          MP_TagBase+14       /*not yet*/
  82. #define BAT_AlphaMod                         MP_TagBase+15       /*not yet*/
  83.  
  84. /* ------------------------------------------------------------*/
  85. /* values for MP_ReadPalette*/
  86.  
  87. #define PT_RGB                   0
  88. #define PT_RRGGBB                1           /*not yet*/
  89. #define PT_RGB4                  2           /*not yet*/
  90. #define PT_RGB32                 3           /*not yet*/
  91. /* ------------------------------------------------------------*//*define EC_OK                              0*/
  92. #define EC_INTERNAL                        1
  93. #define EC_DOS                             2
  94.  
  95. #define EC_OUT_OF_MEMORY                   3
  96. #define EC_COULD_NOT_GET_INFORMATION       4
  97. #define EC_END_OF_FILE                     6
  98. #define EC_PLANENUMBER_NOT_SUPPORTED       7
  99. #define EC_COMPRESSION_NOT_SUPPORTED       8
  100. #define EC_COMPRESSIONMODE_NOT_SUPPORTED   9
  101. #define EC_COMPRESSIONMODE_UNKNOWN         10
  102.  
  103.